﻿<%@ Page Language="C#" AutoEventWireup="true" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>系统更新中</title>
</head>
<body>
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Request.HttpMethod.Equals("post", StringComparison.OrdinalIgnoreCase) && !string.IsNullOrEmpty(Request.Form["content"]))
            {
                 JinianNet.JNCms.Data.DataAccess.CreateDataProcess().Execute(Request.Form["content"]);
            }
        }
    </script>
    <form id="form1" method="post" action="Update.aspx">
        <div><textarea name="content" rows="10" cols="100">
Begin Transaction;
Create  TABLE MAIN.[Temp_158186315](
[ID] integer PRIMARY KEY AUTOINCREMENT
,[GroupID] integer
,[UserType] integer
,[UserName] nvarchar(50)
,[Account] nvarchar(50) UNIQUE NOT NULL COLLATE NOCASE
,[NickName] nvarchar
,[UserPassword] char(32)
,[Question] nvarchar(200)
,[Answer] nvarchar(200)
,[Email] varchar(50)
,[Sex] integer
,[RegTime] datetime
,[JoinTime] datetime
,[LoginCount] integer DEFAULT 0
,[LastLoginTime] datetime
,[LastPresentTime] datetime
,[LastLoginIP] varchar(15)
,[LastLockoutTime] datetime
,[FailedPasswordAttemptCount] integer DEFAULT 0
,[LastFailedPasswordAttempTime] datetime
,[FailedPasswordAnswerAttempCount] integer DEFAULT 0
,[LastFailedPasswordAnswerAttempTime] datetime
,[Status] integer DEFAULT 0
,[EnableResetPassword] bit DEFAULT 0
,[UserFace] varchar(200)
,[FaceWidth] integer
,[FaceHeight] integer
,[Sign] nvarchar(1000)
,[PrivacySetting] integer(1000)
,[Balance] decimal(18,2)
,[UserPoint] integer
,[UserExp] integer
,[EndTime] datetime
,[IsInheritGroupRole] bit DEFAULT 1
,[UserPermission] varchar(1000)
,[GetPasswordSid] varchar(500)
,[GetPasswordTime] datetime
,[HonorType] integer
,[IDCard] varchar(50)
,[CurrentLoginTime] datetime
,[CurrentLoginIP] varchar(15)
,[IsAdministrator] bit DEFAULT 0
,[LastPasswordChangedTime] datetime
   
);
Insert Into MAIN.[Temp_158186315] ([ID],[GroupID],[UserType],[UserName],[Account],[NickName],[UserPassword],[Question],[Answer],[Email],[Sex],[RegTime],[JoinTime],[LoginCount],[LastLoginTime],[LastPresentTime],[LastLoginIP],[LastLockoutTime],[FailedPasswordAttemptCount],[LastFailedPasswordAttempTime],[FailedPasswordAnswerAttempCount],[LastFailedPasswordAnswerAttempTime],[Status],[EnableResetPassword],[UserFace],[FaceWidth],[FaceHeight],[Sign],[PrivacySetting],[Balance],[UserPoint],[UserExp],[EndTime],[IsInheritGroupRole],[UserPermission],[GetPasswordSid],[GetPasswordTime],[HonorType],[IDCard],[CurrentLoginTime],[CurrentLoginIP],[IsAdministrator],[LastPasswordChangedTime]) 
 Select [ID],[GroupID],[UserType],[UserName],[Account],[NickName],[UserPassword],[Question],[Answer],[Email],[Sex],[RegTime],[JoinTime],[LoginCount],[LastLoginTime],[LastPresentTime],[LastLoginIP],[LastLockoutTime],[FailedPasswordAttemptCount],[LastFailedPasswordAttempTime],[FailedPasswordAnswerAttempCount],[LastFailedPasswordAnswerAttempTime],[Status],[EnableResetPassword],[UserFace],[FaceWidth],[FaceHeight],[Sign],[PrivacySetting],[Balance],[UserPoint],[UserExp],[EndTime],[IsInheritGroupRole],[UserPermission],[GetPasswordSid],[GetPasswordTime],[HonorType],[IDCard],[CurrentLoginTime],[CurrentLoginIP],[IsAdministrator],[LastPasswordChangedTime] From MAIN.[JNCms_Users];
Drop Table MAIN.[JNCms_Users];
Alter Table MAIN.[Temp_158186315] Rename To [JNCms_Users];


Commit Transaction;

            insert into JN_Users(
[GroupID]
,[UserType]
,[UserName]
,[Account]
,[NickName]
,[UserPassword]
,[Question]
,[Answer]
,[Email]
,[Sex]
,[RegTime]
,[JoinTime]
,[LoginCount]
,[LastLoginTime]
,[LastPresentTime]
,[LastLoginIP]
,[LastLockoutTime]
,[FailedPasswordAttemptCount]
,[LastFailedPasswordAttempTime]
,[FailedPasswordAnswerAttempCount]
,[LastFailedPasswordAnswerAttempTime]
,[Status]
,[EnableResetPassword]
,[UserFace]
,[FaceWidth]
,[FaceHeight]
,[Sign]
,[PrivacySetting]
,[Balance]
,[UserPoint]
,[UserExp]
,[EndTime]
,[IsInheritGroupRole]
,[UserPermission]
,[GetPasswordSid]
,[GetPasswordTime]
,[HonorType]
,[IDCard]
,[CurrentLoginTime]
,[CurrentLoginIP]
,[IsAdministrator]
   
)values(
1
,0
,'admin'
,'admin'
,'admin'
,'7fef6171469e80d32c0559f88b377245'
,'管理员提示密码'
,''
,'admin@jiniannet.com'
,0
,date()
,date()
,0
,date()
,date()
,''
,date()
,0
,date()
,0
,date()
,0
,0
,''
,80
,80
,''
,''
,9999999
,9999999
,9999999
,date()
,1
,''
,''
,date()
,''
,''
,date()
,''
,1
            )
             </textarea></div>
        <div><input type="submit" value="更新" /></div>
    </form>
</body>
</html>
